{% extends 'index.html' %}
{% block content %}

    <table >
                    <tr>
                        <th>用户名</th>
                        <th>密码</th>
                        <th>图片</th>
                        <th>类别</th>
                        <th>操作</th>
                        <th>修改</th>
                    </tr>
                      {% for i in users %}
                    <tr>
                        <td>{{ i.username }}</td>
                        <td>{{ i.password }}</td>
                        <td><img src="/static/upload/{{ i.img }}" alt=""></td>
                        {% if i.type == 1 %}
                            <td>管理员</td>
                            {% else %}
                            <td>普通用户</td>

                        {% endif %}
                        <td><button><a href="/delete?id={{ i.id }}">删除</a></button></td>
                        <td><button><a href="/update?id={{ i.id }}">修改</a></button></td>
                    </tr>
                  {% endfor %}

                </table>
                        {{ msg }}


{% endblock %}